<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2018/10/20
 * Time: 16:41
 */

namespace app\admin\model;


use think\Model;
use traits\model\SoftDelete;

class UserAddress extends Model
{
    use SoftDelete;
    protected $autoWriteTimestamp = true;
    protected $createTime = 'add_time';
    protected $field = true;
    public function getUSexAttr($val)
    {
        switch ($val){
            case '1':
                return '先生';
                break;
            case '2':
                return '女士';
                break;
            default:
                return '未知';
                break;
        }
    }
}